﻿using System;

namespace Touchmax
{
    public class OpActivity
    {
        private int activityID;
        private bool newClient;
        private int clientID;
        private string firstName;
        private string middleName;
        private string lastName;
        private string address1;
        private string address2;
        private string cityName;
        private string stateCode;
        private string postalCode;
        private string customerGroup;
        private string calllerSex;
        private string callStatus;
        private DateTime callTime;
        private string orderID;
        private int techID;
        private DateTime appointmentDate;
        private decimal amount;
        private int employeeID;
        private DateTime timeFrom;
        private DateTime timeTo;
        private string callNote;
        private string repairNote;
        private int callProcessID;
        private int callSourceID;
        private string time1;
        private string time2;
        private string newClientStatus;
        private string clientType;
        private string technician;
        private string callSource;

        public int ActivityID
        {
            get { return this.activityID; }
        }

        public bool NewClient
        {
            get { return this.newClient; }
            set { this.newClient = value; }
        }

        public int ClientID
        {
            get { return this.clientID; }
            set { this.clientID = value; }
        }

        public string CustName
        {
            get
            {
                string s = "";
                if (this.clientID != null)
                {
                    string sql = "select name from BoClient where CustId='" + SafeValue.SafeInt(this.clientID, 0) + "'";
                    s = SafeValue.SafeString(Touchmax.Manager.ORManager.ExecuteScalar(sql), "");
                }
                return s;
            }
        }

        public string Latitude
        {
            get
            {
                string s = "";
                if (this.clientID != null)
                {
                    string sql = "select latitude from BoClient where CustId='" + SafeValue.SafeInt(this.clientID, 0) + "'";
                    s = SafeValue.SafeString(Touchmax.Manager.ORManager.ExecuteScalar(sql), "");
                }
                return s;
            }
        }

        public string Longitude
        {
            get
            {
                string s = "";
                if (this.clientID != null)
                {
                    string sql = "select longitude from BoClient where CustId='" + SafeValue.SafeInt(this.clientID, 0) + "'";
                    s = SafeValue.SafeString(Touchmax.Manager.ORManager.ExecuteScalar(sql), "");
                }
                return s;
            }
        }



        public string FirstName
        {
            get { return this.firstName; }
            set { this.firstName = value; }
        }

        public string MiddleName
        {
            get { return this.middleName; }
            set { this.middleName = value; }
        }

        public string LastName
        {
            get { return this.lastName; }
            set { this.lastName = value; }
        }

        public string Address1
        {
            get { return this.address1; }
            set { this.address1 = value; }
        }

        public string Address2
        {
            get { return this.address2; }
            set { this.address2 = value; }
        }

        public string CityName
        {
            get { return this.cityName; }
            set { this.cityName = value; }
        }

        public string StateCode
        {
            get { return this.stateCode; }
            set { this.stateCode = value; }
        }

        public string PostalCode
        {
            get { return this.postalCode; }
            set { this.postalCode = value; }
        }

        public string CustomerGroup
        {
            get { return this.customerGroup; }
            set { this.customerGroup = value; }
        }

        public string CalllerSex
        {
            get { return this.calllerSex; }
            set { this.calllerSex = value; }
        }

        public string CallStatus
        {
            get { return this.callStatus; }
            set { this.callStatus = value; }
        }

        public DateTime CallTime
        {
            get { return this.callTime; }
            set { this.callTime = value; }
        }

        public string OrderID
        {
            get { return this.orderID; }
            set { this.orderID = value; }
        }

        public int TechID
        {
            get { return this.techID; }
            set { this.techID = value; }
        }

        public DateTime AppointmentDate
        {
            get { return this.appointmentDate; }
            set { this.appointmentDate = value; }
        }

        public decimal Amount
        {
            get { return this.amount; }
            set { this.amount = value; }
        }

        public int EmployeeID
        {
            get { return this.employeeID; }
            set { this.employeeID = value; }
        }

        public DateTime TimeFrom
        {
            get { return this.timeFrom; }
            set { this.timeFrom = value; }
        }

        public DateTime TimeTo
        {
            get { return this.timeTo; }
            set { this.timeTo = value; }
        }

        public string CallNote
        {
            get { return this.callNote; }
            set { this.callNote = value; }
        }

        public string RepairNote
        {
            get { return this.repairNote; }
            set { this.repairNote = value; }
        }

        public int CallProcessID
        {
            get { return this.callProcessID; }
            set { this.callProcessID = value; }
        }

        public int CallSourceID
        {
            get { return this.callSourceID; }
            set { this.callSourceID = value; }
        }

        public string Time1
        {
            get { return this.time1; }
            set { this.time1 = value; }
        }

        public string Time2
        {
            get { return this.time2; }
            set { this.time2 = value; }
        }

        public string NewClientStatus
        {
            get { return this.newClientStatus; }
            set { this.newClientStatus = value; }
        }

        public string ClientType
        {
            get { return this.clientType; }
            set { this.clientType = value; }
        }

        public string Technician
        {
            get { return this.technician; }
            set { this.technician = value; }
        }

        public string CallSource
        {
            get { return this.callSource; }
            set { this.callSource = value; }
        }
    }
}
